package client.panels.footPanel;


import client.stations.Station;

import com.google.gwt.user.client.ui.Button;
import com.google.gwt.user.client.ui.ClickListener;
import com.google.gwt.user.client.ui.VerticalPanel;
import com.google.gwt.user.client.ui.Widget;


public class FootPanel extends VerticalPanel 
{
	
	private static FootPanel instance = null ;
	public static FootPanel getInstance() 
	{
		if (null == instance) 
		{
			// Premier appel
			instance = new FootPanel();
		}
		return instance;
	}
	
	private FootPanel() 
	{
		Button button = new Button();
		button.setText(" Bouton :) ");
		
		button.addClickListener(				
		new ClickListener()
		{
			public void onClick(Widget sender) 
			{
				Station stat = new Station("Morillon" , "http://www.skiplan.com/php/genererXml.php?pays=france&region=alpes&station=morillon" );
				stat.retrieveInfos();
				
				
			}
		} 
		);
		
		
		this.add(button);
	}
	
}
